const getters = {
  sidebar: state => state.app.sidebar,
  device: state => state.app.device,
  // this.$store.state.user.token
  // this.$store.state.user.info.desc.age

  // 全局getters 快捷映射模块内任意数据
  // this.$store.getters.token
  // this.$store.getters.age
  token: state => state.user.token,
  avatar: state => state.user.avatar,
  name: state => state.user.name,
  // xx(state) {
  //   // return state.xx*3
  //   return 999
  // }
  // state 这是全局state
  // xx: state => state.user.token
  userId: state => state.user.userInfo.userId,
  username: state => state.user.userInfo.username,
  staffPhoto: state => state.user.userInfo.staffPhoto,
  routes: state => state.user.routes
  // store.getters.username
  // store.getters.staffPhoto
}
export default getters
